#include<iostream>
using namespace std;

class A
{
public:
	virtual void Func()
	{
		cout << "class A" << endl;
	}
};

class B :public A
{
public:
	virtual void Func()
	{
		cout << "class B" << endl;
	}
};


int main()
{
	A V1;
	B V2;

	A& ptr = V2;
	A* ptr2 = &V2;



	return 0;
}